Skip to content

Conversation

@mergify
Copy link

@mergify mergify bot commented Jul 11, 2025

Proposed Changes

Soon Mnesia will be gone from RabbitMQ, so better make the test suite metadata store agnostic. (The suite contains unit tests so mocking on a higher level seemed acceptable)

Also refactored mqtt_processor get_vhost functions, in order to clarify preference of different methods. This commit does
not change functionality. (I wanted to prepare an actual change in this area but abandoned the idea. But I think this refactoring makes the code a bit more readable

This highlighted some differences (which I initially thought as inconsistencies, but after digging the history they seem to be intentional and the behaviour is documented in the processor_SUITE)

  • If both User/Password and SslLogin are provided, in
    check_credentials User/Password takes precedence while in
    get_vhost SslLogin

  • If SslLogin is provided (but no mapping is found) vhost from port
    mapping has precedence over vhost from UserName, while in case of
    no ssl it is the other way around.

Types of Changes

What types of changes does your code introduce to this project?
Put an x in the boxes that apply

  • Bug fix (non-breaking change which fixes issue #NNNN)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause an observable behavior change in existing systems)
  • Documentation improvements (corrections, new content, etc)
  • Cosmetic change (whitespace, formatting, etc)
  • Build system and/or CI

Checklist

Put an x in the boxes that apply.
You can also fill these out after creating the PR.
If you're unsure about any of them, don't hesitate to ask on the mailing list.
We're here to help!
This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING.md document
  • I have signed the CA (see https://cla.pivotal.io/sign/rabbitmq)
  • I have added tests that prove my fix is effective or that my feature works
  • All tests pass locally with my changes
  • If relevant, I have added necessary documentation to https://github.com/rabbitmq/rabbitmq-website
  • If relevant, I have added this change to the first version(s) in release-notes that I expect to introduce it

Further Comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution
you did and what alternatives you considered, etc.


This is an automatic backport of pull request #14210 done by [Mergify](https://mergify.com).

Soon Mnesia will be gone from RabbitMQ, so better make the test suite
metadata store agnostic.

(cherry picked from commit 10f1ea1)
In order to clarify preference of different methods. This commit oes
not change functionality.

This highlights some inconsistences:

- If both User/Password and SslLogin are provided, in
  `check_credentials` User/Password takes precedence while in
  `get_vhost` SslLogin

- If SslLogin is provided (but no mapping is found) vhost from port
  mapping has precedence over vhost from UserName, while in case of
  no ssl it is the other way around.

(cherry picked from commit 7d4ecb5)
@ansd
Copy link
Member

ansd commented Jul 11, 2025

Closing since this PR is not a bug fix.

@ansd ansd closed this Jul 11, 2025
@michaelklishin michaelklishin deleted the mergify/bp/v4.1.x/pr-14210 branch July 11, 2025 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants